export default function request(params){
  return new Promise((resolve,reject)=>{
    wx.request({
      url: params.url,
      method: params.method || "GET",
      data:params.data || {},
      success:res=>{
        resolve(res)
      },
      fail:err=>{
        reject(err)
      }
    })
  })
}